package com.detech.sboh.base.enumtype;

/**
* @description 全局统一HTTP响应码
* @author 方安伦
* @date 2022/4/29 14:25
 **/
public enum CodeEnum {

    success(200,"操作成功"),
    logicCheck(202,"逻辑检查不通过"),
    paramError(400,"参数错误"),
    authentication(401,"未登录（需要身份验证）"),
    noPermission(403,"没有权限，访问受限"),
    sysError(500,"系统错误"),
    fail(501,"操作失败"),
    busy(503,"系统繁忙，请稍后再试")
    ;

    private int code;
    private String msg;

    CodeEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }
    public int getCode() {
        return code;
    }
    public String getMsg() {
        return msg;
    }
}
